<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">

<head>

<meta content="text/html; charset=utf-8" http-equiv="Content-Type">

<meta charset="utf-8">

<meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" name="viewport">

<meta content="yes" name="apple-mobile-web-app-capable">

<meta content="black" name="apple-mobile-web-app-status-bar-style">

<meta content="telephone=no" name="format-detection">

<title></title>

<link href="style/login.css" rel="stylesheet" type="text/css" />

<link href="css/vant.css" rel="stylesheet" type="text/css" />

<script src="js/jquery-3.3.1.min.js"></script>

<script src="js/vue.js"></script>

<script src="js/axios.js"></script>

<script src="js/qs.js"></script>

<script src="js/MD5.js"></script>

<script src="js/vant.js"></script>

</head>

<body>

<div id="app">

   

</div>

</body>

<script>

var app = new Vue({

    el: '#app',

    data: {

       vid:'',

       Gtoken:''

    },

    created(){

        this.setCanS()

    },

    methods: {

        //设置参数

        setCanS(){

            //获取登录状态

            let Request = new Object()

            Request = GetRequest()

            this.vid = Request['vid']

            this.Gtoken = Request['Gtoken']

            sessionStorage.setItem('logo','0')

            let type="logo"

            //设置为1代表以及登录 0代表为登录

            let reg=new RegExp('@','g')//g代表全部

            let newMsg=this.Gtoken.replace(reg,'=')

            console.log(newMsg)

            sessionStorage.setItem('token',newMsg)

            sessionStorage.setItem('vid',this.vid)

            localStorage.setItem('adviser',"1")

            localStorage.setItem('adviservid',this.vid)

            localStorage.setItem('adviserGtoken',newMsg)

            //保存登录有效期

            let timeLoc=new Date()

            localStorage.setItem('adviserTime',new Date(timeLoc.getTime() + 365*24*60*60*1000))

            sessionStorage.setItem('type',type)

            window.location.href='index.html?vid='+this.vid+'&type='+type+''

            }

        }

})

</script>

</html>